//
//  WBDemoViewController.swift
//  Weibo
//
//  Created by User on 2017/3/14.
//  Copyright © 2017年 ZFY. All rights reserved.
//

import UIKit

class WBDemoViewController: WBBaseViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        title = "第 \(navigationController?.childViewControllers.count ?? 0) 个"
    }
    
    func showNext() {
        
        let vc = WBDemoViewController()
        
        navigationController?.pushViewController(vc, animated: true)
    }
    
    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
    }
}

extension WBDemoViewController {
    
    override func setupTableView() {
        super.setupTableView()
        
        // 设置导航栏按钮
        wbNavigationItem.rightBarButtonItem = UIBarButtonItem(title: "下一个", normalColor: UIColor.darkGray, highlightedColor: UIColor.orange, target: self, action: #selector(showNext))
    }
}
